//*********************************************************
//
//    Copyright (c) Microsoft. All rights reserved.
//    This code is licensed under the Apache License, Version 2.0.
//    THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF
//    ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY
//    IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR
//    PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.
//
//********************************************************* 


namespace Microsoft.TridentWordAddIn.Common
{
    /// <summary>
    /// Data stored per user
    /// </summary>
    public class UserData
    {
        /// <summary>
        /// Dictionary to map connection name to TridentConnection
        /// </summary>
        private SerializableDictionary<string, TridentConnection> connectionDictionary;

        #region Constructors

        /// <summary>
        /// Initializes a new instance of the <see cref="UserData"/> class.
        /// </summary>
        public UserData() 
        {
            this.connectionDictionary = new SerializableDictionary<string, TridentConnection>();
        }

        #endregion

        #region Public Properties

        /// <summary>
        /// Gets or sets the name of the current connection.
        /// </summary>
        /// <value>The name of the current connection.</value>
        public string CurrentConnectionName { get; set; }

        /// <summary>
        /// Gets or sets the connections.
        /// </summary>
        /// <value>The connections.</value>
        public SerializableDictionary<string, TridentConnection> Connections
        {
            get
            {
                return this.connectionDictionary;
            }
            set
            {
                this.connectionDictionary = value;
            }
        }   

        #endregion
    }
}
